package edu.ahut.spring;

import edu.ahut.spring.pojo.Category;
import org.junit.Test;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import java.util.logging.Logger;


public class TestSpringIOC {
    @Test
    public void testSpringIOC() {


        ApplicationContext context = new ClassPathXmlApplicationContext(new String[]{"applicationContext.xml",});

        Category c = (Category) context.getBean("c");
        Logger.getLogger(getClass().getName()).info(c.getName());

    }
}
